<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html>
<html>

	<head>
		<meta charset="utf-8" />
		
		<title><?php echo C('sitename');?></title>
		<meta name="keywords" content="<?php echo C('keyword');?>">
		<meta name="description" content="<?php echo C('content');?>">

		<meta name="renderer" content="webkit">
		<meta name="format-detection" content="telephone=no,email=no"/>
		<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=0">
		<meta name="telephone=no" content="format-detection">
		<meta name="apple-mobile-web-app-status-bar-style" content="black">
		<meta name="apple-mobile-web-app-capable" content="yes">
		<meta name="format-detection" content="telephone=no" />

		<META HTTP-EQUIV="Pragma" CONTENT="no-cache">
		<META HTTP-EQUIV="Cache-Control" CONTENT="no-cache">
		<META HTTP-EQUIV="Expires" CONTENT="0">

		<link rel="stylesheet" type="text/css" href="/Public/Home/css/lib.css" />
		<link rel="stylesheet" type="text/css" href="/Public/Home/css/public.css" />
		<link rel="stylesheet" type="text/css" href="/Public/Home/css/index.css" />
	</head>
	<style>
		#Cocos2dGameContainer{
			width: 100% !important;
			height: 274px !important;
		}
	</style>
	<body>
		<div class="tab-content">
			
			<div class="tab-box dh" data-img='0' style="height: 274px;background-color: #ccc;">
				<div id="canvas" style="text-align: center; font-size: 0">
					<canvas id="gameCanvas" width="1136" height="640" style="width:117%;height:274px"></canvas>
				</div>
			</div>
			
			<div class="tab-box wz" data-img='1'>
				<table border="" cellspacing="" cellpadding="">
					<thead>
						<tr>
							<th>期号</th>
							<th>开奖时间</th>
							<th>开奖号码</th>
							<th>特码</th>
						</tr>
					</thead>
					<tbody>
						<?php if(is_array($list)): $i = 0; $__LIST__ = $list;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): $mod = ($i % 2 );++$i;?><tr>
								<td><?php echo ($vo["periodnumber"]); ?></td>
								<td><?php echo (date("Y.m.d",strtotime($vo["awardtime"]))); ?><br /><?php echo (date("H:i:s",strtotime($vo["awardtime"]))); ?></td>
								<td class="ft-sz-0">
									<?php
 $number = unserialize($vo['number']); $lh = unserialize($vo['lh']); ?>
									<?php if(is_array($number)): $k = 0; $__LIST__ = $number;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$t): $mod = ($k % 2 );++$k;?><span class="shuzi shuzi_<?php echo ($k); ?>"><?php echo ($t); ?></span><?php endforeach; endif; else: echo "" ;endif; ?>
									<br />
									<strong class="longhu cl-red"><?php echo ($lh[0]); ?></strong>
									<strong class="longhu cl-blue2"><?php echo ($lh[1]); ?></strong>
									<strong class="longhu cl-red"><?php echo ($lh[2]); ?></strong>
									<strong class="longhu cl-blue2"><?php echo ($lh[3]); ?></strong>
									<strong class="longhu cl-blue2"><?php echo ($lh[4]); ?></strong>
								</td>
								<td class="txt-al-c ft-sz-0">
									<span class="tm"><?php echo ($vo["tema"]); ?></span>
									<span class="tm cl-blue2"><?php echo ($vo["tema_dx"]); ?></span>
									<span class="tm cl-red"><?php echo ($vo["tema_ds"]); ?></span><br />
									<span class="tm cl-blue2"><?php echo ($vo["zx"]); ?></span>
									<span class="tm"><?php echo ($vo["tema_dw"]); ?></span>
								</td>
							</tr><?php endforeach; endif; else: echo "" ;endif; ?>
					</tbody>
				</table>
			</div>
		</div>
		
		<div class="main-box">
			<div class="leftRight">
				<div class="nav">
					<div class="portrait no"><img src="<?php echo ($userinfo["headimgurl"]); ?>" /></div>
					<a href="<?php echo U('Home/Circle/kefu');?>" class="portrait active" target="myIframe" data-height='100'><img src="/Public/Home/img/0.png" /></a>
					<a href="<?php echo U('Home/Circle/jincai');?>" class="portrait" target="myIframe" data-height='240'><img src="/Public/Home/img/1.png" /></a>
					<a href="<?php echo U('Home/Circle/record');?>?t=1" class="portrait" target="myIframe" data-height='150'><img src="/Public/Home/img/2.png" /></a>
					<div class="portrait tab-bt" data-bt="0"><img src="/Public/Home/img/7_01.png" /></div>
					<div class="portrait tab-bt" data-bt="1"><img src="/Public/Home/img/4.png" /></div>
					<a onclick="javascript:window.location.href=window.location.href;" class="portrait shuax" target="myIframe"><img src="/Public/Home/img/5.png" /></a>
					<a href="<?php echo U('Home/Circle/rule');?>" class="portrait" target="myIframe" data-height='720'><img src="/Public/Home/img/6.png" /></a>
					<!--<a href="" class="portrait" target="myIframe"><img src="/Public/Home/img/7.png"/></a>-->
				</div>
				<div class="content">
					<!--iframe-->
					<div class="iframewp">
						<iframe id="myIframe" name="myIframe"></iframe>
					</div>
				</div>
			</div>
		</div>	
		
		
		
		<script src='//cdn.bootcss.com/jquery/1.11.3/jquery.js'></script>
		<script src="/Public/layer/layer.js"></script>
		<script type="text/javascript">
			$(function() {
				/*------- 声明对象、参数 -----------*/
				var wp = $('.main-box .leftRight'),
					nav = wp.children('.nav'),
					navli = nav.children('a'),
					con = wp.children('.content'),
					iframe = wp.find('.iframewp');
				var num_hei = 0,
					h = 100;
				/*绑定事件*/
				navli.on('click', function() {
					var _ = $(this);
					navli.removeClass('active').filter(_).addClass('active');
					h = get_dataHei(_);
					alertHei();
					navli.filter('.shuax').attr('href', _.attr('href'));
					navli.filter('.shuax').attr('data-height', _.attr('data-height'));
				});
				/*初始化*/
				//navli.filter('.active').eq(0).children().trigger('click');
				navli.eq(1).children().trigger('click');
				windowAlter(alertHei);
				/*公共方法*/
				function get_dataHei(obj) {
					var _ = obj;
					if(typeof(_.attr('data-height')) != "undefined" && $.trim(_.attr('data-height')).length > 0 && parseInt($.trim(_.attr('data-height'))) > 100) {
						return parseInt($.trim(_.attr('data-height')));
					} else {
						return 100;
					}
				}

				function alertHei() {
					num_hei = nav.outerHeight();
					num_hei = num_hei * (h / 100);
					con.css({
						'height': num_hei + 'px'
					});
					num_hei = num_hei - parseFloat(con.css('padding-top')) - parseFloat(con.css('padding-bottom'));
					if(con.children('.top').is(':visible')) {
						var iframe_hei = num_hei - con.children('.top').outerHeight(true);
					} else {
						var iframe_hei = num_hei;
					}
					iframe.css({
						'height': iframe_hei + 'px'
					});
				}

				function getIndexing(obj) {
					var i = $.inArray(obj[0], navli);
					return 'go' + (i + 1);
				}

				function windowAlter(fun) {
					fun();
					$(window).resize(fun);
				}

				function imgloadstate(imgs, fun, Time) {
					var ys, boole,
						time = Time || 500,
						img = imgs[0];

					function pd() {
						boole = img.complete;
						if(boole) {
							fun();
							clearTimeout(ys);
						} else {
							ys = setTimeout(pd, time);
						}
					}
					pd();
				}

				/*-------------选项卡（hover切换）----------*/
				tab_hover($('.leftRight .nav'), $('.tab-content'));

				function tab_hover(bt, content) {
					bt.each(function(i, e) {
						var _ = $(e);
						var _c = $(content);
						var _bt = _.children('.tab-bt'),
							_box = _c.children('.tab-box');

						_bt.on('click', function() {
							if(!$(this).hasClass('on')) {
								var j = $(this).data('bt'),
									_img = _box.filter('[data-img=' + j + ']');
								if(_img.length > 0) {
									_bt.removeClass('on');
									$(this).addClass('on');
									_box.stop(true, false).hide().removeClass('on').filter('[data-img=' + j + ']').addClass('on').fadeIn().css("display", "block");
								}
							}
						});
					})
				};
			})
		</script>

		<script type="text/javascript">

			alert("bbb");
			var g_hostIp = "http://www.pk103.com/Home/Api/test";
			$.getJSON(g_hostIp,{}, function(b) {
				alert("ccc");
			}

			
			var acontainer = $('#acontainer');
			var hasData = false;
	
			function AddList(data) {
				if(data.length > 0) {
					hasData = true;
					acontainer.html(data[0].data);
					acontainer.show();
				}
			}
			function beforeStartRunning() {
				acontainer.hide();
			}
	
			function afterEndRunning() {
				if(hasData) acontainer.show();
			}

			

		</script>
		
		<!--视频-->
		<!-- <?php if($url == 'pk10'): ?><script src="/Public/main/mbase.js"></script>
			<script src="/Public/main/cocos2d.js"></script>
			<?php else: ?> -->
		<script src="/Public/main/ft/mbase.js"></script>
		<script src="/Public/main/ft/cocos2d.js"></script>
		<!--<?php endif; ?> -->


	
	</body>

</html>